-
Notifications
You must be signed in to change notification settings - Fork 188
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add rotation to Gaussian beam initialization #4767
base: development
Are you sure you want to change the base?
Conversation
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
for more information, see https://pre-commit.ci
@@ -951,6 +951,17 @@ Particle initialization | |||
|
|||
\sigma_{x,y}(z) &= \sigma^*_{x,y} \sqrt{1 + \left( \frac{z - z^*}{\beta^*_{x,y}} \right)^2} | |||
|
|||
* ``<species_name>.do_rotation`` (`bool`, optional) the beam is rotated around its centroid. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we change the user-input name, to make it clear that this argument is specific to the "gaussian_beam" initialization?
* ``<species_name>.do_rotation`` (`bool`, optional) the beam is rotated around its centroid. | |
* ``<species_name>.do_gaussian_beam_rotation`` (`bool`, optional) the beam is rotated around its centroid. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the text, could you also add that this can be used e.g. to initialize beams that are crossing at an angle.
@@ -951,6 +951,17 @@ Particle initialization | |||
|
|||
\sigma_{x,y}(z) &= \sigma^*_{x,y} \sqrt{1 + \left( \frac{z - z^*}{\beta^*_{x,y}} \right)^2} | |||
|
|||
* ``<species_name>.do_rotation`` (`bool`, optional) the beam is rotated around its centroid. | |||
|
|||
If ``do_rotation = 1`` then the user needs to specify: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If ``do_rotation = 1`` then the user needs to specify: | |
If ``do_gaussian_beam_rotation = 1`` then the user needs to specify: |
|
||
If ``do_rotation = 1`` then the user needs to specify: | ||
|
||
* ``<species_name>.rotation_axis``: (list of 3 `doubles`) axis around which the rotation takes place |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* ``<species_name>.rotation_axis``: (list of 3 `doubles`) axis around which the rotation takes place | |
* ``<species_name>.gaussian_beam_rotation_axis``: (list of 3 `doubles`) axis around which the rotation takes place |
|
||
* ``<species_name>.rotation_axis``: (list of 3 `doubles`) axis around which the rotation takes place | ||
|
||
* ``<species_name>.rotation_angle``: (`double`) angle of rotation around the specified axis, in radians. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* ``<species_name>.rotation_angle``: (`double`) angle of rotation around the specified axis, in radians. | |
* ``<species_name>.gaussian_beam_rotation_angle``: (`double`) angle of rotation around the specified axis, in radians. |
|
||
|
||
Note that the other beam parameters (e.g. ``<species_name>.x/y/z_rms``, etc.) are used in the initialization process `before` performing the rotation. | ||
Therefore, the user should define the beam size, cuts, and focal distance for the beam pre-rotatation, hence aligned to the Cartesian axes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Therefore, the user should define the beam size, cuts, and focal distance for the beam pre-rotatation, hence aligned to the Cartesian axes. | |
Therefore, the user should define the beam size, cuts, and focal distance for the beam pre-rotation, hence aligned to the Cartesian axes. |
This adds the option to rotate in space a species initialized as a Gaussian beam.
The rotation is performed around a user-defined axis by a user-defined angle.